package com.bosssoft.permission.centre.pojo.dto.pcp;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.sd365.common.core.common.pojo.dto.TenantBaseDTO;

import java.beans.Transient;
import java.util.Date;
import java.util.List;


public class UserDTO extends TenantBaseDTO {
    /**
     * 角色用户所拥有的角色 可以通过 ResultMap <collection 指定子查询获取
     */

    private List<RoleDTO> roleList;

    /**
     * 角色用户所拥有的部门 可以通过 ResultMap <assocation 指定子查询获取
     * 你也考可以考虑分开查询 或者 不带该字段
     */

    private DepartmentDTO department;

    /**
     * 说明同上
     */

    private PositionDTO position;

    /**
     * 公司和组织机构以及租户也可以采用以上方式
     */

    /**
     * 工号
     */

    private String code;

    /**
     * 密码
     */

    private String password;

    /**
     * 名字
     */

    private String name;

    /**
     * 头像
     */

    private String profilePicture;

    /**
     * 性别
     */

    private Byte sex;

    /**
     * 生日
     */

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date birthday;

    /**
     * 电话
     */

    private String tel;

    /**
     * 邮箱
     */

    private String email;

    /**
     * 其他联系
     */

    private String other;

    /**
     * 备注
     */

    private String remark;

    /**
     * 部门ID
     */

    private Long departmentId;

    /**
     * 职位ID  注意这个不等同于角色实际就是岗位
     */

    private Long positionId;

    /**
     * 公司
     */

    private CompanyDTO company;

    /**
     * 组织
     */

    private OrganizationDTO organization;

    /**
     * 工号
     */
    public String getCode() {
        return code;
    }

    /**
     * 工号
     */
    public void setCode(String code) {
        this.code = code;
    }

    /**
     * 密码
     */
    public String getPassword() {
        return password;
    }

    /**
     * 密码
     */
    public void setPassword(String password) {
        this.password = password;
    }

    /**
     * 名字
     */
    public String getName() {
        return name;
    }

    /**
     * 名字
     */
    public void setName(String name) {
        this.name = name;
    }

    /**
     * 头像
     */
    public String getProfilePicture() {
        return profilePicture;
    }

    /**
     * 头像
     */
    public void setProfilePicture(String profilePicture) {
        this.profilePicture = profilePicture;
    }

    /**
     * 性别
     */
    public Byte getSex() {
        return sex;
    }

    /**
     * 性别
     */
    public void setSex(Byte sex) {
        this.sex = sex;
    }

    /**
     * 生日
     */
    public Date getBirthday() {
        return birthday;
    }

    /**
     * 生日
     */
    public void setBirthday(Date birthday) {
        this.birthday = birthday;
    }

    /**
     * 电话
     */
    public String getTel() {
        return tel;
    }

    /**
     * 电话
     */
    public void setTel(String tel) {
        this.tel = tel;
    }

    /**
     * 邮箱
     */
    public String getEmail() {
        return email;
    }

    /**
     * 邮箱
     */
    public void setEmail(String email) {
        this.email = email;
    }

    /**
     * 其他联系
     */
    public String getOther() {
        return other;
    }

    /**
     * 其他联系
     */
    public void setOther(String other) {
        this.other = other;
    }

    /**
     * 备注
     */
    public String getRemark() {
        return remark;
    }

    /**
     * 备注
     */
    public void setRemark(String remark) {
        this.remark = remark;
    }

    /**
     * 部门ID
     */
    public Long getDepartmentId() {
        return departmentId;
    }

    /**
     * 部门ID
     */
    public void setDepartmentId(Long departmentId) {
        this.departmentId = departmentId;
    }

    /**
     * 职位ID  注意这个不等同于角色实际就是岗位
     */
    public Long getPositionId() {
        return positionId;
    }

    /**
     * 职位ID  注意这个不等同于角色实际就是岗位
     */
    public void setPositionId(Long positionId) {
        this.positionId = positionId;
    }

    public List<RoleDTO> getRoleList() {
        return roleList;
    }

    public void setRoleList(List<RoleDTO> roleList) {
        this.roleList = roleList;
    }

    public DepartmentDTO getDepartment() {
        return department;
    }

    public void setDepartment(DepartmentDTO department) {
        this.department = department;
    }

    public PositionDTO getPosition() {
        return position;
    }

    public void setPosition(PositionDTO position) {
        this.position = position;
    }

    public CompanyDTO getCompany() {
        return company;
    }

    public void setCompany(CompanyDTO company) {
        this.company = company;
    }

    public OrganizationDTO getOrganization() {
        return organization;
    }


    public void setOrganization(OrganizationDTO organization) {
        this.organization = organization;
    }


    public String toStr() {
        return "UserDTO{" +
                "roleList=" + roleList +
                ", department=" + department +
                ", position=" + position +
                ", code='" + code + '\'' +
                ", password='" + password + '\'' +
                ", name='" + name + '\'' +
                ", profilePicture='" + profilePicture + '\'' +
                ", sex=" + sex +
                ", birthday=" + birthday +
                ", tel='" + tel + '\'' +
                ", email='" + email + '\'' +
                ", other='" + other + '\'' +
                ", remark='" + remark + '\'' +
                ", departmentId=" + departmentId +
                ", positionId=" + positionId +
                ", company=" + company +
                ", organization=" + organization +
                '}';
    }
}




